R Course

Jürgen Wilbert

University of Potsdam

10/20/22

Todays goals

  • Introduction to the idea of Data Science

  • Getting an overview of the content of this seminar

  • Installing R on your computer

  • Installing R-Studio on your computer

  • Overview of R-Studio

What is R?

  • A tool for statistical computation (like SPSS, Mplus, STATA …)
  • A programming language
  • An idea and a community that shares common ideas about science

Statements

  • Science should be truthful
  • Science should be diligent
  • Science should be transparent
  • Science should be reproducible
  • Science should be communicated
  • Science should be accessible
  • Science should be open

R (and R studio)

  • Science should be truthful
  • Science should be diligent
  • Science should be transparent
  • Science should be reproducible
  • Science should be communicated
  • Science should be accessible
  • Science should be open

What R can do

Statistical analyses

  • Descriptive stats
  • Modeling
  • Inferential stats
  • Manage and organize data
  • Large data (large scale / big data / EEG / fMRT)
  • Small data (experimental data / questionnaire data / single-case data)

Present data

  • Visualize data and results
  • Keep a notebook of your research and analyses
  • Write reports, including stats
  • Write presentations
  • Write books
  • Build interactive websites
  • Connect with various other software and internet tools

Schedule

# Topic
1 Installation R, R Studio, and other software
2 Basics of R: Logic and syntax
3 Basics of R: Subsetting
4 Markdown
5 Data manipulation with tidyverse
6 Basic statistics
7 Data visualizazion with ggplot2
8 Regression analyses with R

Installation of R and R-Studio

Installing R

R homepage: https://www.r-project.org/

Installing R-Studio

https://www.rstudio.com/products/rstudio/download/

Download RStudio-Desktop for free

Installing R tools (windows only)

  • Windows user have to install additional programs that allow for compiling R packages.
  • This is necessary when you want to install certain extensions to R (packages).
  • You can install it from here: https://cran.r-project.org/bin/windows/Rtools/
  • Choose the version that corresponds to the version of R that you installed previously.
  • Linux or MacOs users have this software already installed.

Install Quarto

  • Quarto is a program that allows for publishing documents that contain Output (tabels, plots etc.) created with R.

  • You can install it from here: https://quarto.org/

R for Data science

R for Data Science is a terrific book and completely free!